Hi,
I'm trying to get the url of a baseline, without loading the baseline first.
After reading the documentation, I think the following code should work:
//-----------------------------------------------------
ModuleVersion mv = moduleVersion(current Module)
string fname = fullName(mv)
Baseline a = getMostRecentBaseline(current Module)
ModName_ mn = module(fname)
Moduleversion mvb = moduleVersion(mn, a)
string strUrl = getURL(mvb)
//-------------------------------------------------
However, when I run the code, strUrl is blank. Is there something I'm doing wrong, or is it just not possible to retrieve the url without using the 'load' command.
Thanks.
Agustine
P.S. I'm running on Doors 8.1
dasilvaa - Tue Feb 10 15:27:06 EST 2009 |
|
Re: Retrieving URL from baseline Doug.Zawacki - Tue Feb 10 16:29:02 EST 2009
Well, I couldn't get it to work without loading the baseline also. Here is the code that worked for me.
ModuleVersion mv = moduleVersion(current Module)
string fname = fullName(mv)
Baseline a = getMostRecentBaseline(current Module,true)
ModName_ mn = module(fname)
ModuleVersion mvb = moduleVersion(mn,a)
load(mvb,false)
string strUrl = getURL(mvb)
print "Baselined URL:" strUrl "\n"
|
|
Re: Retrieving URL from baseline dasilvaa - Wed Feb 11 09:02:01 EST 2009 Doug.Zawacki - Tue Feb 10 16:29:02 EST 2009
Well, I couldn't get it to work without loading the baseline also. Here is the code that worked for me.
ModuleVersion mv = moduleVersion(current Module)
string fname = fullName(mv)
Baseline a = getMostRecentBaseline(current Module,true)
ModName_ mn = module(fname)
ModuleVersion mvb = moduleVersion(mn,a)
load(mvb,false)
string strUrl = getURL(mvb)
print "Baselined URL:" strUrl "\n"
Hi Doug,
If you're going to do a 'load', why not just 'load' the Baseline a?
There's a reason why I didn't want to load the baseline. If you load the baseline, you should close if after you're done, but if you do, there's a bug.
After retrieving the URL and closing the module, try editing (current version) one of the module level attributes (e.g. Description). If you try to save, the system says it cannot save the module because it's locked by a user - yourself!
Has anyone encountered this?
|
|